package com.epidemic.project.system.tongzhi.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.epidemic.project.system.tongzhi.mapper.SysTongZhiMapper;
import com.epidemic.project.system.tongzhi.domain.SysTongZhi;
import com.epidemic.project.system.tongzhi.service.ISysTongZhiService;
import com.epidemic.common.utils.text.Convert;

/**
 * 通知Service业务层处理
 * 
 * @author sys
 * @date 2023-02-01
 */
@Service
public class SysTongZhiServiceImpl implements ISysTongZhiService 
{
    @Autowired
    private SysTongZhiMapper sysTongZhiMapper;

    /**
     * 查询通知
     * 
     * @param id 通知ID
     * @return 通知
     */
    @Override
    public SysTongZhi selectSysTongZhiById(Long id)
    {
        return sysTongZhiMapper.selectSysTongZhiById(id);
    }

    /**
     * 查询通知列表
     * 
     * @param sysTongZhi 通知
     * @return 通知
     */
    @Override
    public List<SysTongZhi> selectSysTongZhiList(SysTongZhi sysTongZhi)
    {
        return sysTongZhiMapper.selectSysTongZhiList(sysTongZhi);
    }

    /**
     * 新增通知
     * 
     * @param sysTongZhi 通知
     * @return 结果
     */
    @Override
    public int insertSysTongZhi(SysTongZhi sysTongZhi)
    {
        return sysTongZhiMapper.insertSysTongZhi(sysTongZhi);
    }

    /**
     * 修改通知
     * 
     * @param sysTongZhi 通知
     * @return 结果
     */
    @Override
    public int updateSysTongZhi(SysTongZhi sysTongZhi)
    {
        return sysTongZhiMapper.updateSysTongZhi(sysTongZhi);
    }

    /**
     * 删除通知对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteSysTongZhiByIds(String ids)
    {
        return sysTongZhiMapper.deleteSysTongZhiByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除通知信息
     * 
     * @param id 通知ID
     * @return 结果
     */
    @Override
    public int deleteSysTongZhiById(Long id)
    {
        return sysTongZhiMapper.deleteSysTongZhiById(id);
    }
}
